﻿<UserControl x:Class="WpUserControls.UserControls.ToggleSwitch"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    d:DesignHeight="82" d:DesignWidth="186">

    <Grid x:Name="LayoutRoot">
        <Border Name="LayoutBorder">
            <Grid HorizontalAlignment="Center" VerticalAlignment="Center">
                <StackPanel Orientation="Horizontal">
                    <Border CornerRadius="8,0,0,8" Name="LeftButton" Width="70" Height="40">
                        <TextBlock Name="LeftTextBlock" Text="ON" HorizontalAlignment="Center" VerticalAlignment="Center" />
                        <Border.Background>
                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                <GradientStop Color="#FF48483E" Offset="0" />
                                <GradientStop Color="#FF787878" Offset="1" />
                            </LinearGradientBrush>
                        </Border.Background>
                    </Border>

                    <Border CornerRadius="0,8,8,0" Name="RightButton" Width="70" Height="40" Margin="-8,0,0,0">
                        <TextBlock Name="RightTextBlock" Text="OFF" HorizontalAlignment="Center" VerticalAlignment="Center" />
                        <Border.Background>
                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                <GradientStop Color="#FF48483E" Offset="0" />
                                <GradientStop Color="#FF787878" Offset="1" />
                            </LinearGradientBrush>
                        </Border.Background>
                    </Border>
                </StackPanel>
                <Border Name="SelectedButton" Width="74" Height="44" HorizontalAlignment="Right" CornerRadius="8">
                    <TextBlock Name="SelectedText" HorizontalAlignment="Center" VerticalAlignment="Center" Text="OFF" Foreground="Black"/>
                    <Border.Background>
                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                            <GradientStop Color="Yellow" Offset="0" />
                            <GradientStop Color="#FFAAAA44" Offset="1" />
                        </LinearGradientBrush>
                    </Border.Background>
                </Border>
            </Grid>
        </Border>
    </Grid>
</UserControl>
